import  {get,gets,post,puts} from  "./http.js";
import api from  "./api";


const newsQuery  = (params,headers)=> get(api.newsQuery,params,headers);
const newStatechange  = (data,headers)=> puts(api.newStatechange,data,headers);
const newsQueryById  = (id,headers)=> gets(api.newsQueryById+id,headers);
const newsAdd  =(data,headers)=> post(api.newsAdd,data,headers);


export  { newsQuery,newStatechange,newsQueryById,newsAdd };